package com.xdb.sqlparser.dialect.mysql.ast.statement;

import java.util.ArrayList;
import java.util.List;

import com.xdb.sqlparser.ast.SQLExpr;
import com.xdb.sqlparser.ast.SQLName;
import com.xdb.sqlparser.dialect.mysql.visitor.MySqlASTVisitor;

public class MySqlExecuteStatement extends MySqlStatementImpl {

	private SQLName statementName;
	private final List<SQLExpr> parameters = new ArrayList<SQLExpr>();

	public SQLName getStatementName() {
		return statementName;
	}

	public void setStatementName(SQLName statementName) {
		this.statementName = statementName;
	}

	public List<SQLExpr> getParameters() {
		return parameters;
	}

	public void accept0(MySqlASTVisitor visitor) {
		if (visitor.visit(this)) {
			acceptChild(visitor, statementName);
			acceptChild(visitor, parameters);
		}
		visitor.endVisit(this);
	}
}
